package com.kitty.web.system.rediscache.service.impl;

import com.kitty.web.domain.Rediscache;
import com.kitty.web.mapper.RediscacheMapper;
import com.kitty.web.system.rediscache.service.IRediscacheService;
import com.kitty.web.core.Convert;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


/**
 * 充值排行榜Service业务层处理
 * 
 * @author soul
 * @date 2022-03-15
 */
@Service
public class RediscacheServiceImpl implements IRediscacheService
{
    @Autowired
    private RediscacheMapper rediscacheMapper;

    /**
     * 查询充值排行榜
     * 
     * @param id 充值排行榜ID
     * @return 充值排行榜
     */
    @Override
    public Rediscache selectRediscacheById(Long id)
    {
        return rediscacheMapper.selectRediscacheById(id);
    }

    /**
     * 查询充值排行榜列表
     * 
     * @param rediscache 充值排行榜
     * @return 充值排行榜
     */
    @Override
    public List<Rediscache> selectRediscacheList(Rediscache rediscache)
    {
        return rediscacheMapper.selectRediscacheList(rediscache);
    }

    /**
     * 新增充值排行榜
     * 
     * @param rediscache 充值排行榜
     * @return 结果
     */
    @Override
    public int insertRediscache(Rediscache rediscache)
    {
        return rediscacheMapper.insertRediscache(rediscache);
    }

    /**
     * 修改充值排行榜
     * 
     * @param rediscache 充值排行榜
     * @return 结果
     */
    @Override
    public int updateRediscache(Rediscache rediscache)
    {
        return rediscacheMapper.updateRediscache(rediscache);
    }

    /**
     * 删除充值排行榜对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteRediscacheByIds(String ids)
    {
        return rediscacheMapper.deleteRediscacheByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除充值排行榜信息
     * 
     * @param id 充值排行榜ID
     * @return 结果
     */
    @Override
    public int deleteRediscacheById(Long id)
    {
        return rediscacheMapper.deleteRediscacheById(id);
    }
}
